---
title: "Where do parties talk about what? Party issue salience across communication channels"
subtitle: ""
author:
- "Christoph Ivanusch"
date: ""
link-citations: yes
urlcolor: red
toc: false
output:
  pdf_document:
    keep_md: true
header-includes:
  - \usepackage{lipsum}
  - \usepackage{float}
  - \usepackage{subfig}
  - \captionsetup{belowskip=12pt,aboveskip=4pt}
  - \usepackage{setspace}

---


```{r, setup, include=FALSE, echo=FALSE, warning=FALSE, message=FALSE}

# chunk option defaults
knitr::opts_chunk$set(echo = FALSE, message = FALSE)

# packages
library(quanteda)
library(quanteda.textstats)
library(tidyverse)
library(dplyr)
library(xlsx)
library(readxl)
library(lubridate)
library(ggplot2)
library(gridExtra)
library(formattable)
library(xtable)
library(kableExtra)
library(ggeffects)
library(effects)
library(manifestoR)
library(zoo)
library(miceadds)
library(stargazer)
library(estimatr)
library(lfe)
library(patchwork)
library(plm)
library(lmtest)

# custom function
printT <- function(x) {formatC(x, format='d', big.mark=',')}

```

```{r Preparation - load data sets, echo=FALSE, warning=FALSE, message=FALSE}

main_data <- readRDS("Main_Data.RDS")

load("Text_Data.RDA")

```

\singlespacing

# Main paper

## Figure 1

```{r theoretical framework, warning=FALSE, message=FALSE, echo=FALSE, fig.align="center", fig.pos = "H", out.width="80%", fig.cap = "Factors expected to influence party issue salience in different communication channels (H1-H3). \\label{fig_1}"}

knitr::include_graphics("Figure_1.png")

```

\newpage

## Table 1

```{r table 1, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

tab_1 <- data.frame(Type = c('Parl. speeches', 'Press releases',
                             'Tweets (party)', 'Tweets (person)'), 
                    mediated = c('0', '1', '0', '0'),
                    centralized = c('0.5', '0.5', '1', '0'),
                    pre_structured = c('1', '0', '0', '0'))

colnames(tab_1) <- c('Type', 'Mediated', 'Centralized', 'Pre-structured')

print(xtable(tab_1, align = c('l', 'l', 'c', 'c', 'c'),
      caption = 'Comparison of characteristics per party communication channel. \\label{tab_1}'),
      caption.placement = 'top',
      hline.after = c(-1, 0, 4), comment = FALSE, include.rownames = FALSE)

```

## Table 2

```{r table 2, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

tab_2 <- data.frame(Type = c('Parl. speeches', 'Press releases',
                             'Tweets (party)', 'Tweets (person)',
                             'All'), 
                    N = c(nrow(data_parlspeeches), nrow(data_pressreleases),
                         nrow(data_tweets_party), nrow(data_tweets_person),
                         sum(nrow(data_parlspeeches), nrow(data_pressreleases),
                         nrow(data_tweets_party), nrow(data_tweets_person))))
tab_2$N <- printT(tab_2$N)

print(xtable(tab_2, align = c('l', 'l', 'r'),
      caption = 'Number of documents per text type. \\label{tab_2}'),
      caption.placement = 'top',
      hline.after = c(-1, 0, 4, 5), comment = FALSE, include.rownames = FALSE)

```

\newpage

## Figure 2

```{r figure 2, warning=FALSE, message=FALSE, echo=FALSE, fig.align='center', out.width='100%', fig.cap = 'Issue salience across communication channels compared to manifestos. \\label{fig_2}'}

df_fig_2.1 <- as.data.frame(table(data_pressreleases$issue) / sum(table(data_pressreleases$issue)) * 100)
df_fig_2.1$type <- 'Press releases'

df_fig_2.2 <- as.data.frame(table(data_tweets_party$issue) / sum(table(data_tweets_party$issue)) * 100)
df_fig_2.2$type <- 'Tweets (party)'

df_fig_2.3 <- as.data.frame(table(data_tweets_person$issue) / sum(table(data_tweets_person$issue)) * 100)
df_fig_2.3$type <- 'Tweets (person)'

df_fig_2.4 <- as.data.frame(table(data_parlspeeches$issue) / sum(table(data_parlspeeches$issue)) * 100)
df_fig_2.4$type <- 'Parl. speeches'

df_fig_2.5 <- as.data.frame(table(manifesto_corpus$issue) / sum(table(manifesto_corpus$issue)) * 100)
df_fig_2.5$type <- 'Manifestos'

df_fig_2 <- rbind(df_fig_2.1, df_fig_2.2, df_fig_2.3, df_fig_2.4) %>%
  left_join(df_fig_2.5[, 1:2], by = c('Var1'))
colnames(df_fig_2) <- c('issue', 'salience', 'type', 'manifesto_salience')
df_fig_2$salience_difference <- df_fig_2$salience - df_fig_2$manifesto_salience

ggplot(df_fig_2, aes(y = fct_rev(issue), x = salience_difference, group = type, fill = type)) + 
  geom_bar(stat = 'identity',  position=position_dodge()) +
  scale_fill_brewer(palette='RdYlBu') +
  theme_bw() +
  ggtitle('') +
  labs(x = 'Percent', y = 'Issue', fill = 'Channel') +
  geom_vline(xintercept = 0, linetype = 'dashed') +
  ggplot2::annotate('text', x = 0, y = 21.1, label = 'Manifestos') +
  coord_cartesian(ylim = c(0, 20), clip = 'off') +
  scale_y_discrete(labels = c('Technology and Infrastructure' = 'Technology and\nInfrastructure'))

```

\newpage

## Table 3

```{r table 3, warning=FALSE, message=FALSE, echo=FALSE, results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_mediated)

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_centralized)

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured)

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "tab_3",
          notes = "Standard errors in parentheses.")

```

\newpage

## Figure 3

```{r figure 3, warning=FALSE, message=FALSE, echo=FALSE, fig.align='center', out.width='100%', fig.cap = 'Predicted influence of communication channel characteristics on party issue salience. \\label{fig_3}'}

# mediated
fig_3.1 <- lm(salience ~
                manifesto_salience +
                mediated + 
                manifesto_salience:mediated + 
                time_since_last_election +
                country + party + issue + quarter,
              data = df_mediated) %>%
  ggeffect(terms = c('manifesto_salience', 'mediated'), 
                    vcov.fun = 'vcovBK', 
                    vcov.type = 'vcovHC',
                    vcov.args = list(cluster = df_mediated$group, df_mediated$quarter),
           ci.lvl = 0.90) %>%
  plot(ci = TRUE, alpha=0.3, colors = "bw") +
  ggtitle('') +
  theme_bw() +
  ylim(-1, 30) +
  labs(x = 'Manifesto salience', y = 'Salience', color = 'Mediated')

# centralized
fig_3.2 <- lm(salience ~
                manifesto_salience + 
                centralized +
                manifesto_salience:centralized + 
                time_since_last_election +
                country + party + issue + quarter,
              data = df_centralized) %>%
  ggeffect(c('manifesto_salience', 'centralized'), 
                    vcov.fun = 'vcovBK', 
                    vcov.type = 'vcovHC',
                    vcov.args = list(cluster = df_centralized$group, df_centralized$quarter),
           ci.lvl = 0.9) %>% 
  plot(ci = TRUE, alpha=0.3, colors = "bw") +
  ggtitle('') +
  theme_bw() +
  ylim(-1, 30) +
  labs(x = 'Manifesto salience', y = 'Salience', color = 'Centralized')

## pre-structured
fig_3.3 <- lm(salience ~
                manifesto_salience +
                prestructured + 
                manifesto_salience:prestructured + 
                time_since_last_election +
                country + party + issue + quarter, 
              data = df_prestructured) %>%
  ggeffect(c('manifesto_salience', 'prestructured'),
                    vcov.fun = 'vcovBK',
                    vcov.type = 'vcovHC',
                    vcov.args = list(cluster = df_prestructured$group, df_prestructured$quarter),
           ci.lvl = 0.90) %>%
  plot(ci = TRUE, alpha=0.3, colors = "bw") +
  ggtitle('') +
  theme_bw() +
  ylim(-1, 30) +
  labs(x = 'Manifesto salience', y = 'Salience', color = 'Pre-structured')

wrap_plots(list(fig_3.1, fig_3.2, fig_3.3), ncol = 2)

```

\newpage

# Appendix

## A.1 Number of documents per party and text type

```{r appendix a 1, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

# preparation
df_appendix_a <- left_join(
  data_parlspeeches %>%
  dplyr::count(party),
  data_pressreleases %>%
  count(party),
  by = "party") %>%
  left_join(data_tweets_party %>%
  count(party),
  by = "party") %>%
  left_join(data_tweets_person %>%
  count(party),
  by = "party") %>%
  filter(party != "fraktionslos") %>%
  filter(party != "ohne Klubzugehörigkeit")

colnames(df_appendix_a) <- c("party", 
                             "Parl. speeches", "Press releases",
                             "Tweets (party)", "Tweets (person)")

df_appendix_a <- left_join(data_pressreleases %>%
                             select(country, party) %>%
                             unique(),
                           df_appendix_a)

colnames(df_appendix_a)[1:2] <- c("Country", "Party")

df_appendix_a$`Parl. speeches` <- printT(df_appendix_a$`Parl. speeches`)
df_appendix_a$`Press releases` <- printT(df_appendix_a$`Press releases`)
df_appendix_a$`Tweets (party)` <- printT(df_appendix_a$`Tweets (party)`)
df_appendix_a$`Tweets (person)` <- printT(df_appendix_a$`Tweets (person)`)

df_appendix_a$Party <- gsub("Mitte", "CVP/Mitte", df_appendix_a$Party)

# table
print(xtable(df_appendix_a, auto = TRUE,
             align = c("l", "l", "l", "c", "c", "c", "c"),
             caption = "Number of documents per party and text type. \\label{appendix_a1}"),
      caption.placement = "top",
      hline = c(-1, 0, 19), comment = FALSE, include.rownames = FALSE)

```

```{r , warning=FALSE, message=FALSE, echo=FALSE, fig.align="center", out.width="100%", fig.cap = "Number of documents per text type over time. \\label{appendix_a2}"}

grid.arrange(
  ggplot(data_parlspeeches, aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Parl. speeches") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ggplot(data_pressreleases, aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Press releases") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ggplot(data_tweets_party, aes(x = as.Date(created_at))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (party)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ggplot(data_tweets_person, aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (person)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ncol = 2
  
)

```

```{r , warning=FALSE, message=FALSE, echo=FALSE, fig.align="center", out.width="100%", fig.cap = "Number of documents per text type over time (Austria). \\label{appendix_a3}"}

grid.arrange(
  filter(data_parlspeeches, country == "AT") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Parl. speeches") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_pressreleases, country == "AT") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Press releases") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_party, country == "AT") %>%
    ggplot(aes(x = as.Date(created_at))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (party)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_person, country == "AT") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (person)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ncol = 2
  
)

```

```{r , warning=FALSE, message=FALSE, echo=FALSE, fig.align="center", out.width="100%", fig.cap = "Number of documents per text type over time (Switzerland). \\label{appendix_a4}"}

grid.arrange(
  filter(data_parlspeeches, country == "CH") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Parl. speeches") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_pressreleases, country == "CH") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Press releases") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_party, country == "CH") %>%
    ggplot(aes(x = as.Date(created_at))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (party)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_person, country == "CH") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (person)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ncol = 2
  
)

```

```{r , warning=FALSE, message=FALSE, echo=FALSE, fig.align="center", out.width="100%", fig.cap = "Number of documents per text type over time (Germany). \\label{appendix_a5}"}

grid.arrange(
  filter(data_parlspeeches, country == "DE") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Parl. speeches") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_pressreleases, country == "DE") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Press releases") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_party, country == "DE") %>%
    ggplot(aes(x = as.Date(created_at))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (party)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  filter(data_tweets_person, country == "DE") %>%
    ggplot(aes(x = as.Date(date))) +
    geom_histogram(aes(y=..count..),, binwidth = 7, position="identity", alpha=0.5) +
    geom_density(aes(y=..count..*7), alpha=.3) +
    xlab("Date") +
    ylab("Tweets (person)") +
    theme_bw() +
    scale_x_date(date_labels = "%m/%y") +
    theme(axis.text.x = element_text(angle = 90)),
  ncol = 2
  
)

```

\newpage

## A.2 Overview of Twitter accounts from individual party members

```{r appendix b load, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

account_list <- read.xlsx('Twitter_Person_Accounts_List.xlsx',
                          sheetIndex = 1)

```

```{r appendix b 1, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

df_appendix_b1 <- account_list %>%
  select(country, party, name) %>%
  group_by(country, party) %>%
  tally()

df_appendix_b1$party <- gsub("Mitte", "CVP/Mitte", df_appendix_b1$party)

colnames(df_appendix_b1) <- c("Country", "Party", "N")

# table
print(xtable(df_appendix_b1, auto = TRUE,
             align = c("l", "l", "l", "c"),
             caption = "Number of accounts from individual party members contained in the data set per party (please note that individual party members can simultaneously occupy several roles, such as party leader and MP). \\label{appendix_b_1}"),
      caption.placement = "top",
      hline = c(-1, 0, 19), comment = FALSE, include.rownames = FALSE)

```

```{r appendix b 2, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

appendix_b2 <- unlist(account_list$role) %>%
  strsplit("; ") %>%
  unlist()

tab_appendix_b2 <- table(appendix_b2)

df_appendix_b2 <- data.frame(Role = names(tab_appendix_b2),
                             N = as.numeric(tab_appendix_b2))

# table
print(xtable(df_appendix_b2, auto = TRUE,
             align = c("l", "l", "c"),
             caption = "Overview of roles within a party (party leader, general secretary, MP) covered in the tweets from individual party members. \\label{appendix_b_2}"),
      caption.placement = "top", comment = FALSE, include.rownames = FALSE)

```

\newpage

```{r appendix b 3, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

account_list$party <- gsub("Mitte", "CVP/Mitte", account_list$party)

df_appendix_b3 <- account_list
colnames(df_appendix_b3) <- c("Country", "Party", "Name", "Role")

# table
kable(df_appendix_b3,
      format = "latex", booktabs = TRUE, longtable = TRUE, row.names = TRUE,
      caption = "List of accounts from individual party members and their respective roles contained in the data set. \\label{appendix_b_3}",
      label = NA)  %>%
  kable_styling(latex_options = c("repeat_header"), font_size = 8)

```

\newpage

## A.3 Codebook

```{r appendix c, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

codebook <- read.xlsx("Codebook.xlsx",
                      sheetIndex = 1, colIndex = c(5:6)) %>%
  filter(!is.na(issue)) 

# delete MARPOR handbook 1-4 codes excluded in handbook 5
idx_delete <- c()
for(i in 1:nrow(codebook)) {
  tmp <- codebook$code[i]
  if(length(which(str_detect(codebook$code, tmp) == TRUE)) > 1) {
    idx_tmp <- which(codebook$code == tmp)
    idx_delete <- c(idx_delete, idx_tmp)
  }
}

codebook <- codebook[-idx_delete, ] %>%
  group_by(issue) %>%
  summarise(MARPOR_codes = paste(code, collapse = ", "))
colnames(codebook) <- c("Issue", "MRG/CMP/MARPOR codes")


print(xtable(codebook, auto = TRUE,
             align = c("p{0.2in}", "p{2in}", "p{2.5in}"),
             caption = "Adapted codebook based on Manifesto Project (MRG/CMP/MARPOR) coding scheme. \\label{appendix_c}"),
      caption.placement = "top",
      hline = c(-1, 0, 20), comment = FALSE, rownames = FALSE)

```

\newpage

## A.5 Validation procedure of cross-domain topic classification

```{r appendix e, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

# Intercoder reliability

df <- round(
  data.frame(
    Intercoder_codes = c(0.61, 0.57, 0.61),
    Intercoder_topics = c(0.70, 0.62, 0.66)),
  digits = 2)

rownames(df) <- c('Press releases', 'Parl. speeches', 'Tweets')

knitr::kable(df, 'latex', booktabs = T, escape = F,
             col.names = c('MRG/CMP/MARPOR codes', 'Issues'),
             caption = 'Intercoder agreement for manual coding of press releases, parliamentary speeches and tweets. The first column shows the agreement based on the Manifestos Project (MRG/CMP/MARPOR) code level, the second based on the level of the aggregated issue categories laid out in the codebook. \\label{appendix_e}',
             label = "e",
             align = c('c', 'c'))  %>%
  kable_styling(latex_options=c('HOLD_position'))

```

\newpage

## A.6 Accuracy and F1 scores for cross-domain topic classification

```{r appendix f, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

# source validation files
source('Validation_Pressreleases.R')
source('Validation_ParlSpeeches.R')
source('Validation_Tweets.R')

# accuracy
df_acc <- data.frame(
  'press releases' = c(acc_pressreleases, acc_pressreleases_AT, acc_pressreleases_CH, acc_pressreleases_DE),
  'parl. speeches' = c(acc_parlspeeches, acc_parlspeeches_AT, acc_parlspeeches_DE, acc_parlspeeches_CH),
  'tweets' = c(acc_tweets, acc_tweets_AT, acc_tweets_CH, acc_tweets_DE)
)

rownames(df_acc) <- c('Overall', 'AT', 'CH', 'DE')
colnames(df_acc) <- c('Press releases', 'Parl. speeches', 'Tweets')

knitr::kable(df_acc, 'latex', booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Accuracy scores for computer-based topic classification. \\label{appendix_f_1}',
             label = "f")  %>%
  kable_styling(latex_options=c('HOLD_position'))

# balanced accuracy
df_balacc <- data.frame(
  'press releases' = c(balacc_pressreleases, balacc_pressreleases_AT, balacc_pressreleases_CH, balacc_pressreleases_DE),
  'parl. speeches' = c(balacc_parlspeeches, balacc_parlspeeches_AT, balacc_parlspeeches_DE, balacc_parlspeeches_CH),
  'tweets' = c(balacc_tweets, balacc_tweets_AT, balacc_tweets_CH, balacc_tweets_DE)
)

rownames(df_balacc) <- c('Overall', 'AT', 'CH', 'DE')
colnames(df_balacc) <- c('Press releases', 'Parl. speeches', 'Tweets')

knitr::kable(df_balacc, 'latex', booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Balanced accuracy scores for computer-based topic classification. \\label{appendix_f_2}',
             label = "f")  %>%
  kable_styling(latex_options=c('HOLD_position'))

# macro-averaged f1
df_f1 <- data.frame(
  'press releases' = c(f1_pressreleases, f1_pressreleases_AT, f1_pressreleases_CH, f1_pressreleases_DE),
  'parl. speeches' = c(f1_parlspeeches, f1_parlspeeches_AT, f1_parlspeeches_DE, f1_parlspeeches_CH),
  'tweets' = c(f1_tweets, f1_tweets_AT, f1_tweets_CH, f1_tweets_DE)
)

rownames(df_f1) <- c('Overall', 'AT', 'CH', 'DE')
colnames(df_f1) <- c('Press releases', 'Parl. speeches', 'Tweets')

knitr::kable(df_f1, 'latex', booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Macro-averaged f1 scores for computer-based topic classification. \\label{appendix_f_3}',
             label = "f")  %>%
  kable_styling(latex_options=c('HOLD_position'))

```

\newpage

## A.7 Further validation measures for cross-domain topic classification

```{r appendix g, warning=FALSE, message=FALSE, echo=FALSE, results = 'asis'}

# Press releases
source('Validation_Pressreleases.R')

df_acc <- df_acc[order(rownames(df_acc)), 5:7]
colnames(df_acc) <- c('Precision', 'Recall', 'F1-score')
df_acc[, 1:3] <- round(df_acc[, 1:3], digits = 2)

knitr::kable(df_acc, booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Precision, recall and F1-scores for the computer-based topic classification of press releases. \\label{appendix_g1}',
             label = "g1") %>% 
  kable_styling(latex_options=c('HOLD_position'))

# Parliamentary speeches
source('Validation_ParlSpeeches.R')

df_acc <- df_acc[order(rownames(df_acc)), 5:7]
colnames(df_acc) <- c('Precision', 'Recall', 'F1-score')
df_acc[, 1:3] <- round(df_acc[, 1:3], digits = 2)

knitr::kable(df_acc, booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Precision, recall and F1-scores for the computer-based topic classification of parliamentary speeches. \\label{appendix_g2}',
             label = "g2") %>% 
  kable_styling(latex_options=c('HOLD_position'))

# Tweets
source('Validation_Tweets.R')

df_acc <- df_acc[order(rownames(df_acc)), 5:7]
colnames(df_acc) <- c('Precision', 'Recall', 'F1-score')
df_acc[, 1:3] <- round(df_acc[, 1:3], digits = 2)

knitr::kable(df_acc, booktabs = T, escape = F,
             align = c('c', 'c', 'c'),
             caption = 'Precision, recall and F1-scores for the computer-based topic classification of tweets. \\label{appendix_g3}',
             label = "g3") %>%
  kable_styling(latex_options=c('HOLD_position'))

```

\newpage

## A.8 Issue salience across communication channels

```{r appendix h, warning=FALSE, message=FALSE, echo=FALSE, fig.align='center', out.width='100%', fig.cap = 'Issue salience across communication channels compared to manifestos. \\label{fig_2}'}

df_1 <- as.data.frame(table(manifesto_corpus$issue) / sum(table(manifesto_corpus$issue)) * 100)
colnames(df_1) <- c('Issue', 'Manifestos')

df_2 <- as.data.frame(table(data_parlspeeches$issue) / sum(table(data_parlspeeches$issue)) * 100)
colnames(df_2) <- c('Issue', 'Parl. speeches')

df_3 <- as.data.frame(table(data_pressreleases$issue) / sum(table(data_pressreleases$issue)) * 100)
colnames(df_3) <- c('Issue', 'Press releases')

df_4 <- as.data.frame(table(data_tweets_party$issue) / sum(table(data_tweets_party$issue)) * 100)
colnames(df_4) <- c('Issue', 'Tweets (party)')

df_5 <- as.data.frame(table(data_tweets_person$issue) / sum(table(data_tweets_person$issue)) * 100)
colnames(df_5) <- c('Issue', 'Tweets\n(person)')

df_appendix_f <- df_1 %>%
  left_join(df_2) %>%
  left_join(df_3) %>%
  left_join(df_4) %>%
  left_join(df_5)
df_appendix_f[, 2:6] <- round(df_appendix_f[, 2:6], digits = 2)
df_appendix_f[, 1] <- as.character(df_appendix_f[, 1])

df_appendix_f %>%
  mutate_all(linebreak) %>%
  kable(booktabs = T, escape = F,
        align = c('l', 'c', 'c', 'c', 'c', 'c'),
        col.names =  c('Issue', 'Manifestos', 'Parl. speeches', 'Press releases', 'Tweets (party)', 'Tweets (person)'),
        caption = 'Issue salience (in percent) for manifestos, parliamentary speeches, press releases, tweets from party accounts and tweets from individual party members. \\label{appendix_h}',
        label = "h") %>%
  kable_styling(latex_options=c('HOLD_position', 'scale_down'))

```

\newpage

## A.9 Robustness check: Country-specific regression models

```{r appendix i - AT, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, country == "AT") %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_mediated)

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, country == "AT") %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_centralized)

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, country == "AT") %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured)

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience in Austria.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_i_at",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix i - DE, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, country == "DE") %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, country == "DE") %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, country == "DE") %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience in Germany.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_i_de",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix i - CH, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, country == "CH") %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, country == "CH") %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, country == "CH") %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience in Switzerland.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_i_ch",
          notes = "Standard errors in parentheses.")

```

\newpage

## A.10 Robustness check: Differences between government and opposition parties

```{r appendix j - government, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, government == 1) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, government == 1) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, government == 1) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience for government parties.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_j_gov",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix j - opposition, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, government == 0) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, government == 0) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, government == 0) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience for opposition parties.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_j_opp",
          notes = "Standard errors in parentheses.")

```

\newpage

## A.11 Robustness check: Differences between mainstream and niche parties

```{r appendix k - mainstream, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, niche_party == 0) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, niche_party == 0) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, niche_party == 0) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience for mainstream parties.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_k_mainstream",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix k - niche, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, niche_party == 1) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, niche_party == 1) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, niche_party == 1) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience for niche parties.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_k_niche",
          notes = "Standard errors in parentheses.")

```

\newpage

## A.12 Robustness check: Differences between 'routine times' and campaign periods

```{r appendix l - routine times, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, campaign == 0) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, campaign == 0) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, campaign == 0) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience during non-campaign times.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_l_1",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix l - campaign, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, campaign == 1) %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, campaign == 1) %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, campaign == 1) %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience during campaign periods.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_l_2",
          notes = "Standard errors in parentheses.")

```

\newpage

## A.13 Robustness check: Potential effects caused by Covid-19 pandemic

```{r appendix m - pre covid, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, 
                      quarter < "2020.1" | quarter == "2020.3" | quarter == "2021.3") %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, 
                         quarter < "2020.1" | quarter == "2020.3" | quarter == "2021.3") %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data, 
                           quarter < "2020.1" | quarter == "2020.3" | quarter == "2021.3") %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience before the Covid-19 pandemic and during periods with comparatively low problem pressure.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_m_1",
          notes = "Standard errors in parentheses.")

```

\newpage

```{r appendix m - covid, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# Regression - mediated
df_mediated <- filter(main_data, 
                      quarter >= "2020.1" & quarter != "2020.3" & quarter != "2021.3") %>%
  filter(type == 'Press releases' | type == 'Tweets (party)')
df_mediated$mediated <- 0
df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
df_mediated$mediated <- as.factor(df_mediated$mediated)

df_mediated$group <- paste0(df_mediated$party, "-", 
                            df_mediated$issue, "-", 
                            df_mediated$type)

pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))

reg_1.1 <- plm(salience ~ 
                 manifesto_salience + 
                 mediated + 
                 manifesto_salience*mediated + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_mediated) 

reg_1.2 <- coeftest(reg_1.1, 
                    vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))

# Regression - centralized
df_centralized <- filter(main_data, 
                         quarter >= "2020.1" & quarter != "2020.3" & quarter != "2021.3") %>%
  filter(type == 'Tweets (party)' | type == 'Tweets (person)')
df_centralized$centralized <- 0
df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
df_centralized$centralized <- as.factor(df_centralized$centralized)

df_centralized$group <- paste0(df_centralized$party, "-", 
                               df_centralized$issue, "-", 
                               df_centralized$type)

pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))

reg_2.1 <- plm(salience ~ 
                 manifesto_salience + 
                 centralized + 
                 manifesto_salience*centralized + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter), 
               model = "pooling", 
               data = pdata_centralized) 

reg_2.2 <- coeftest(reg_2.1, 
                    vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))

# Regression - pre-structured
df_prestructured <- filter(main_data,
                           quarter >= "2020.1" & quarter != "2020.3" & quarter != "2021.3") %>%
  filter(type == 'Press releases' | type == 'Parl. speeches')
df_prestructured$prestructured <- 0
df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)

df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                 df_prestructured$issue, "-", 
                                 df_prestructured$type)

pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))

reg_3.1 <- plm(salience ~ 
                 manifesto_salience + 
                 prestructured + 
                 manifesto_salience*prestructured + 
                 time_since_last_election +
                 as.factor(country) + 
                 as.factor(party) +
                 as.factor(issue) +
                 as.factor(quarter),
               model = "pooling", 
               data = pdata_prestructured) 

reg_3.2 <- coeftest(reg_3.1, 
                    vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))

stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = "Influence of communication channel characteristics on party issue salience during periods with comparatively high problem pressure caused by the Covid-19 pandemic.", 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = "appendix_m_2",
          notes = "Standard errors in parentheses.")

```

\newpage

## A.14 Robustness check: Regression models following jackknife logic to control for issue-specific effects

```{r appendix_n, warning=FALSE, message=FALSE, echo=FALSE, fig.pos = 'H', results='asis'}

# preparation
issue_list <- as.character(sort(unique(main_data$issue)))

res_mediated <- c()
res_centralized <- c()
res_prestructured <- c()

# for-loop to calculate models following jackknife logic
for(i in 1:length(issue_list)) {
  
  issue_tmp <- issue_list[i]
  
  # Regression - mediated
  df_mediated <- filter(main_data, issue != issue_tmp) %>%
    filter(type == 'Press releases' | type == 'Tweets (party)')
  df_mediated$mediated <- 0
  df_mediated$mediated[df_mediated$type == 'Press releases'] <- 1
  df_mediated$mediated <- as.factor(df_mediated$mediated)
  
  df_mediated$group <- paste0(df_mediated$party, "-", 
                              df_mediated$issue, "-", 
                              df_mediated$type)
  
  pdata_mediated <- pdata.frame(df_mediated, index = c("group", "quarter"))
  
  reg_1.1 <- plm(salience ~ 
                   manifesto_salience + 
                   mediated + 
                   manifesto_salience*mediated + 
                   time_since_last_election +
                   as.factor(country) + 
                   as.factor(party) +
                   as.factor(issue) +
                   as.factor(quarter), 
                 model = "pooling", 
                 data = pdata_mediated) 
  
  reg_1.2 <- coeftest(reg_1.1, 
                      vcov=plm::vcovBK(reg_1.1, type = "HC0", cluster = "group"))
  
  # Regression - centralized
  df_centralized <- filter(main_data, issue != issue_tmp) %>%
    filter(type == 'Tweets (party)' | type == 'Tweets (person)')
  df_centralized$centralized <- 0
  df_centralized$centralized[df_centralized$type == 'Tweets (party)'] <- 1
  df_centralized$centralized <- as.factor(df_centralized$centralized)
  
  df_centralized$group <- paste0(df_centralized$party, "-", 
                                 df_centralized$issue, "-", 
                                 df_centralized$type)
  
  pdata_centralized <- pdata.frame(df_centralized, index = c("group", "quarter"))
  
  reg_2.1 <- plm(salience ~ 
                   manifesto_salience + 
                   centralized + 
                   manifesto_salience*centralized + 
                   time_since_last_election +
                   as.factor(country) + 
                   as.factor(party) +
                   as.factor(issue) +
                   as.factor(quarter), 
                 model = "pooling", 
                 data = pdata_centralized) 
  
  reg_2.2 <- coeftest(reg_2.1, 
                      vcov=plm::vcovBK(reg_2.1, type = "HC0", cluster = "group"))
  
  # Regression - pre-structured
  df_prestructured <- filter(main_data, issue != issue_tmp) %>%
    filter(type == 'Press releases' | type == 'Parl. speeches')
  df_prestructured$prestructured <- 0
  df_prestructured$prestructured[df_prestructured$type == 'Parl. speeches'] <- 1
  df_prestructured$prestructured <- as.factor(df_prestructured$prestructured)
  
  df_prestructured$group <- paste0(df_prestructured$party, "-", 
                                   df_prestructured$issue, "-", 
                                   df_prestructured$type)
  
  pdata_prestructured <- pdata.frame(df_prestructured, index = c("group", "quarter"))
  
  reg_3.1 <- plm(salience ~ 
                   manifesto_salience + 
                   prestructured + 
                   manifesto_salience*prestructured + 
                   time_since_last_election +
                   as.factor(country) + 
                   as.factor(party) +
                   as.factor(issue) +
                   as.factor(quarter),
                 model = "pooling", 
                 data = pdata_prestructured) 
  
  reg_3.2 <- coeftest(reg_3.1, 
                      vcov=plm::vcovBK(reg_3.1, type = "HC0", cluster = "group"))
  
  # print table
  title_tmp <- paste0("Influence of communication channel characteristics on party issue salience with issue `", issue_tmp, "' removed from the analysis.") 
  label_tmp <- paste0("jackknife", i)
  
  stargazer(reg_1.2, reg_2.2, reg_3.2,
          keep = c("manifesto_salience", 
                   "mediated", 
                   "centralized",
                   "prestructured",
                   "manifesto_salience:mediated", 
                   "manifesto_salience:centralized",
                   "manifesto_salience:prestructured",
                   "time_since_last_election"),
          type = "latex",
          header = FALSE,
          title = title_tmp, 
          keep.stat = c("n", "rsq", "adj.rsq"),
          dep.var.labels = "Issue salience",
          order = c("manifesto_salience$", 
                    "mediated", 
                    "centralized",
                    "prestructured",
                    "manifesto_salience:mediated1",
                    "manifesto_salience:centralized1",
                    "manifesto_salience:prestructured1",
                    "time_since_last_election"),
          covariate.labels = c("Manifesto salience",
                               "Mediated",
                               "Manifesto salience:Mediated",
                               "Centralized",
                               "Manifesto salience:Centralized",
                               "Pre-structured",
                               "Manifesto salience:Pre-structured",
                               "Quarters since last election"),
          add.lines = list(c("Country FEs", "Yes", "Yes", "Yes"),
                           c("Party FEs", "Yes", "Yes", "Yes"),
                           c("Issue FEs", "Yes", "Yes", "Yes"),
                           c("Quarter FEs", "Yes", "Yes", "Yes"),
                           c("\\hline"),
                           c("R-squared", 
                             round(summary(reg_1.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[1]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[1]], digits = 3)),
                           c("Adj. R-squared", 
                             round(summary(reg_1.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_2.1)$r.squared[[2]], digits = 3),
                             round(summary(reg_3.1)$r.squared[[2]], digits = 3)),
                           c("Num. obs.",
                             printT(nrow(df_mediated)),
                             printT(nrow(df_centralized)),
                             printT(nrow(df_prestructured)))),
          
          label = label_tmp,
          notes = "Standard errors in parentheses.")
  
}

```
